<template>
	<view class="flex-colume-start indexResultPage">
		<view style="height: 30rpx;"></view>
		<view class="flex-row-center" style="background-color: white; width: 640rpx; border-radius: 20rpx; height: 249rpx;">
			<image src="/static/bg1.png" style="width: 580rpx; height: 245rpx;"></image>
		</view>
		<view class="flex-colume-start" style="margin-top: 30rpx; background-color: white; width: 640rpx; border-radius: 20rpx; padding: 40rpx; box-sizing: border-box;">
			<view class="flex-row-start item1" >
				<view class="title1">姓名：</view>
				<view class="desc1">{{name}}</view>
			</view>
			<view class="flex-row-start item1" >
				<view class="title1">评分：</view>
				<view class="desc1" :style="formType==3?'color:green;':'color:red;'">{{score}}</view>
			</view>
			<view class="flex-row-start item1">
				<view class="title1">风控等级：</view>
				<view class="desc1">{{formType == 3?'较低':'较高'}}</view>
			</view>
			<view class="flex-row-start item1">
				<view class="title1">原因：</view>
				<text class="desc1" v-if="formType != 3">
					虚假商户 疑似套现
					非银联认证机型
					消费习惯与常规不吻合
				</text>
				<text class="desc1" v-else>
					用卡记录良好
					机型认证成功
					消费习惯与常规吻合
				</text>
			</view>
			
			<view style="margin-top: 30rpx; margin-bottom: -30rpx; font-size: 24rpx; color: rgb(153, 153, 153);">Copyright @2025</view>
		</view>
		
		
		
	</view>
</template>

<script>
	export default {
		data() {
			return {
				formType:0,
				name:'',
				score:0
				
			}
		},
		onLoad(e){
			this.formType = e.formType
			this.name = e.name
			if (e.formType == 0 || e.formType == 1){
				this.score = this.getRandomIntInclusive(26, 29);
			}
			if (e.formType == 2){
				this.score =  this.getRandomIntInclusive(30, 40);
			}
			if (e.formType == 3){
				this.score =  this.getRandomIntInclusive(87, 93);
			}
			
			
		},
		methods: {
			getRandomIntInclusive(min, max) {
			  min = Math.ceil(min);
			  max = Math.floor(max);
			  return Math.floor(Math.random() * (max - min + 1)) + min; //含两端点
			}
			 
		

			
			
		}
	}
</script>

<style lang="scss" scoped>
	.indexResultPage{
		.item1{
			width: 100%;
			align-items: flex-start;
			font-size: 28rpx;
			line-height: 50rpx;
			margin-bottom: 8rpx;
			margin-top: 8rpx;
			color: rgb(54, 54, 54);
			.title1{
				width: 180rpx;
				
				text-align: left;
			}
		}
		
	}

</style>
